<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>服务-护理培训/培训义工管理</title>
    <meta content='width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no' name='viewport'>
    <jsp:include page="../com/header.jsp"></jsp:include>
    <script type="text/javascript" src="../../js/comm/listcomm.js"></script>
    <script type="text/javascript">
        var contentUrl = root + "cms/nurseTraining/findNurseTrainingNEStatusPage";
        var editUrl = 'nurseTrainingEdit.jsp?id=';
        var operateUrl = root + 'cms/nurseTraining/operateNurseTrainingByIds';
        var detailurl=root + 'cms/nurseTraining/findNurseTrainingById';
        function getfilter() {
            var _jsonFilter = "{";
            if ($("#search_NurseTraining_Name").val() && $("#search_NurseTraining_Name").val().length > 0) {
                _jsonFilter += "'search_EQ_NurseTraining_Name':'" + $("#search_NurseTraining_Name").val().replace("'", "\"") + "',";
            }
            if ($("#search_NurseTraining_StartTime").val() && $("#search_NurseTraining_StartTime").val().length > 0) {
                _jsonFilter += "'search_EQ_NurseTraining_StartTime':'" + $("#search_NurseTraining_StartTime").val().replace("'", "\"") + "',";
            }
            if ($("#search_NurseTraining_EndTime").val() && $("#search_NurseTraining_EndTime").val().length > 0) {
                _jsonFilter += "'search_EQ_NurseTraining_EndTime':'" + $("#search_NurseTraining_EndTime").val().replace("'", "\"") + "',";
            }
            if ($("#search_NurseTraining_Address").val() && $("#search_NurseTraining_Address").val().length > 0) {
                _jsonFilter += "'search_EQ_NurseTraining_Address':'" + $("#search_NurseTraining_Address").val().replace("'", "\"") + "',";
            }
            if ($("#search_NurseTraining_organization").val() && $("#search_NurseTraining_organization").val().length > 0) {
                _jsonFilter += "'search_EQ_NurseTraining_organization':'" + $("#search_NurseTraining_organization").val().replace("'", "\"") + "',";
            }
            if ($("#search_quantity").val() && $("#search_quantity").val().length > 0) {
                _jsonFilter += "'search_EQ_quantity':'" + $("#search_quantity").val().replace("'", "\"") + "',";
            }
            if ($("#search_price").val() && $("#search_price").val().length > 0) {
                _jsonFilter += "'search_EQ_price':'" + $("#search_price").val().replace("'", "\"") + "',";
            }
            if ($("#search_quantityInventory").val() && $("#search_quantityInventory").val().length > 0) {
                _jsonFilter += "'search_EQ_quantityInventory':'" + $("#search_quantityInventory").val().replace("'", "\"") + "',";
            }
            if (($("#endTime").val() && $("#endTime").val().length > 0) && $("#startTime").val().length <= 0) {
                _jsonFilter += "'search_LTE_orderStartTime':'" + $("#endTime").val() + "',";
            }
            if (($("#endTime").val() && $("#endTime").val().length > 0) && ($("#startTime").val() && $("#startTime").val().length > 0)) {
                _jsonFilter += "'search_BETWEEN_orderStartTime':'" + $("#startTime").val() + "," + $("#endTime").val() + "',";
            }


            if ($("#search_NurseTraining_Content").val() && $("#search_NurseTraining_Content").val().length > 0) {
                _jsonFilter += "'search_EQ_NurseTraining_Content':'" + $("#search_NurseTraining_Content").val().replace("'", "\"") + "',";
            }
            if ($("#search_nurseTraining_url").val() && $("#search_nurseTraining_url").val().length > 0) {
                _jsonFilter += "'search_EQ_nurseTraining_url':'" + $("#search_nurseTraining_url").val().replace("'", "\"") + "',";
            }
            if (_jsonFilter != "{") {
                _jsonFilter = _jsonFilter.substring(0, _jsonFilter.length - 1);
            }
            _jsonFilter += "}";
            return _jsonFilter;
        }
    </script>
</head>
<body>
<section>
    <div>
        <div class="col-xs-12">
            <div class="box">
                <form id="search_form" class="form-horizontal">
                    <div class="tabSelect" id="selectHeadId">
                        <br>
                        <div class="form-group  col-md-3 search-form">
                            <label class="col-md-4 control-label controls">培训名称：</label>
                            <div class="col-md-8">
                                <input type="text" placeholder="培训名称" class="form-control input-sm"
                                       id="search_NurseTraining_Name" name="NurseTraining_Name"/>
                            </div>
                        </div>
                  <!--       <div class="form-group  col-md-3 search-form">
                            <label class="col-md-4 control-label controls">培训开始时间：</label>
                            <div class="col-md-8" style="padding-right:0;position:relative;">
                                <div class="datetime_clear"></div>
                                <input type="text" readOnly placeholder="开始时间" class="form-control input-sm"
                                       id="startTime1" name="search_NurseTraining_StartTime"/>
                            </div>
                        </div>
                        <div class="form-group  col-md-3 search-form">
                            <label class="col-md-1 control-label controls">至</label>
                            <div class="col-md-8" style="padding-right:0;position:relative;">
                                <div class="datetime_clear"></div>
                                <input type="text" readOnly placeholder="结束时间" class="form-control input-sm"
                                       id="endTime1" name="search_NurseTraining_StartTime"/>
                            </div>
                        </div>

                        <div class="form-group  col-md-3 search-form">
                            <label class="col-md-4 control-label controls">培训地址：</label>
                            <div class="col-md-8">
                                <input type="text" placeholder="培训地址" class="form-control input-sm"
                                       id="search_NurseTraining_Address" name="NurseTraining_Address"/>
                            </div>
                        </div> -->


                        <div class="form-group  col-md-3 search-form">
                            <label class="col-md-4 control-label controls">培训单位：</label>
                            <div class="col-md-8">
                                <input type="text" placeholder="培训单位" class="form-control input-sm"
                                       id="search_NurseTraining_organization" name="NurseTraining_organization"/>
                            </div>
                        </div>


                        <div class="form-group  col-md-3 search-form">
                            <label class="col-md-4 control-label controls">报名开始时间：</label>
                            <div class="col-md-8" style="padding-right:0;position:relative;">
                                <div class="datetime_clear"></div>
                                <input type="text" readOnly placeholder="开始时间" class="form-control input-sm"
                                       id="startTime" name="orderStartTime"/>
                            </div>
                        </div>
                        <div class="form-group  col-md-3 search-form">
                            <label class="col-md-1 control-label controls">至</label>
                            <div class="col-md-8" style="padding-right:0;position:relative;">
                                <div class="datetime_clear"></div>
                                <input type="text" readOnly placeholder="结束时间" class="form-control input-sm"
                                       id="endTime" name="orderStartTime"/>
                            </div>
                        </div>

                        <input type="button" value="查询" id="search" class="btn btn-primary searchBtn">
                    </div>
                </form>
                <div class="box-body table-responsive" style="clear:both;">
                    <input type="button" value="新增" id="addSome" class="btn btn-success">
                    <input type="button" value="编辑" id="updateSome" class="btn btn-info">
                    <input type="button" value="删除" id="deleteSome" class="btn btn-danger">
                    <input type="button" value="查看" id="detailgold" class="btn btn-color">
                </div>
                <div class="box-body table-responsive">
                    <table id="example2" class="table table-bordered table-hover">
                        <thead>
                        <tr>
                            <th width="30"><input type="checkbox" id="_selectAll"/></th>
                            <th width="80">培训岗位</th>
                            <th width="80">开始时间</th>
                            <th width="80">培训地址</th>
                            <th width="80">培训单位</th>
<!--                             <th width="80">培训总名额</th> -->
                            <th width="80">客服电话</th>
                            <th width="80">培训价格</th>
<!--                             <th width="80">名额库存</th> -->
                            <th width="30">排序值</th>
                            <th width="30">点击量</th>
<!--                             <th width="80">报名开始时间</th> -->
                            <th width="80">培训中心图片</th>
                            <th width="80">状态</th>
                        </tr>
                        </thead>
                        <!-- 表格内容 start -->
                        <tbody id="mycontent"></tbody>
                        <!-- 表格内容 end -->
                    </table>
                    <!-- 分页标签 start -->
                    <div class="row page_big_div" id="displayPage"></div>
                    <!-- 分页标签 end -->
                    <script id="tableContentTmple" type="text/x-jsrender">
								<tr>
									<td><input id="ck_{{:id}}" ckId="{{:id}}" ckStatus="{{:status}}" class="ckSelect" type="checkbox" /></td>
									<td style="vertical-align:middle; text-align:left;">{{:nurseTraining_Name}}</td>
									<td>{{:nurseTraining_StartTime}}</td>
									<td title={{:nurseTraining_Address}} style="vertical-align:middle; text-align:left;">{{subStrings:nurseTraining_Address lens=8}}</td>
									<td title={{:nurseTraining_organization}} style="vertical-align:middle; text-align:left;">{{subStrings:nurseTraining_organization lens=8}}</td>
									<%--<td>{{:quantity}}</td>--%>
									<td>{{:mobile}}</td>
									<td title={{:price}} style="vertical-align:middle; text-align:right;">{{toThousands:price}}</td>
									<%--<td>{{:quantityInventory}}</td>--%>
									<td>{{:sort}}</td>
									<td>{{:clickCont}}</td>
									<%--<td>{{:orderStartTime}}</td>--%>
									<td>
										{{if nurseTraining_url}}
                                         	<img src="../../{{:nurseTraining_url}}" class="img" height="40" width="50">
                                     	{{/if}}
									</td>
									<td>{{if status==1}}正常{{else status==2}}已发布{{else status==3}}已删除{{else status==-1}}已锁定{{else}}无效{{/if}}</td>
								</tr>

                    </script>
                </div>
            </div>
        </div>
</section>
	<!-- 详细信息 -->
      <div class="modal fade" id="myModals" tabindex="-1" role="dialog"
		aria-labelledby="myModalLabel" aria-hidden="true">
		<form id="validateForm" class="form-horizontal">
			<div class="modal-dialog">
				<div class="modal-content" style="width:900px;margin-left:-100px;">
					<div class="modal-header">
						<button type="button" class="close" data-dismiss="modal"
							aria-hidden="true">&times;</button>
						<h4 class="modal-title" id="myModalLabel">详细信息</h4>
					</div>
					<div class="modal-body detail">
						
					</div>
					<div class="modal-bodyclass">
                       	    <script id="commentContentTmple" type="text/x-jsrender">
                             <div class="form-group">
			                    	<label for="userPhoto2" class="control-label col-md-2">培训岗位：</label>
			                       	<div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                  {{:nurseTraining_Name}}
				                    </div>
				                    <label for="userPhoto2" class="control-label col-md-2">培训地址：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                  {{:nurseTraining_Address}}
				                    </div>
			                </div>
                             <div class="form-group">
			                    	<label for="userPhoto2" class="control-label col-md-2">培训单位：</label>
			                       	<div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:nurseTraining_organization}}
				                    </div>
				                    <label for="userPhoto2" class="control-label col-md-2">培训总名额：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:quantity}}
				                    </div>
			                </div>
							<div class="form-group">
									<label for="userPhoto2" class="control-label col-md-2">客服电话：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:mobile}}
				                    </div>
									<label for="userPhoto2" class="control-label col-md-2">培训价格：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:price}}
				                    </div>
							</div>
							<div class="form-group">
									<label for="userPhoto2" class="control-label col-md-2">名额库存：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:quantityInventory}}
				                    </div>
									<label for="userPhoto2" class="control-label col-md-2">开始时间：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:nurseTraining_StartTime}}
				                    </div>
							</div>
							<div class="form-group">
									<label for="userPhoto2" class="control-label col-md-2">点击量：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:clickCont}}
				                    </div>
									<label for="userPhoto2" class="control-label col-md-2">排序值：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:sort}}
				                    </div>
							</div>
							<div class="form-group">
									<label for="userPhoto2" class="control-label col-md-2">报名开始时间：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{:orderStartTime}}
				                    </div>
									<label for="userPhoto2" class="control-label col-md-2">状态：</label>
				                    <div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                 {{if status==1}}正常{{else status==2}}已发布{{else status==3}}已删除{{else status==-1}}已锁定{{else}}无效{{/if}}
				                    </div>
							</div>
							<div class="form-group">
			                    	<label for="userPhoto2" class="control-label col-md-2">培训中心图片:</label>
			                       	<div class="controls col-md-3" style="line-height:30px;font-weight:normal;">
					                  {{if nurseTraining_url}}
                                         	<img src="../../{{:nurseTraining_url}}" class="img" height="40" width="50">
                                     	{{/if}}
				                    </div>
			                </div>
                            </script>
                    </div>
                    <div class="modal-footer">
						<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
					</div>
				</div>
			</div>
		</form>
	</div>
</body>
</html>